package com.center.biz.impl;

import com.center.api.model.EduWebsiteProfile;
import com.center.api.remote.RemoteEduWebsiteProfileService;
import com.center.biz.dao.EduWebsiteProfileMapper;
import org.apache.dubbo.config.annotation.Service;
import org.springframework.beans.factory.annotation.Autowired;

import java.util.List;

@Service(version = "1.0",interfaceClass = RemoteEduWebsiteProfileService.class)
public class RemoteEduWebsiteProfileServiceImpl implements RemoteEduWebsiteProfileService{

    @Autowired
    private EduWebsiteProfileMapper eduWebsiteProfileMapper;

    @Override
    public int save(EduWebsiteProfile eduWebsiteProfile) {
        return eduWebsiteProfileMapper.insertSelective(eduWebsiteProfile);
    }

    @Override
    public int update(EduWebsiteProfile eduWebsiteProfile) {
        return eduWebsiteProfileMapper.updateByPrimaryKeySelective(eduWebsiteProfile);
    }

    @Override
    public int delete(int id) {
        return eduWebsiteProfileMapper.deleteByPrimaryKey(id);
    }

    @Override
    public List<EduWebsiteProfile> select(EduWebsiteProfile eduWebsiteProfile) {
        return null;
    }

    @Override
    public EduWebsiteProfile getById(int id) {
        return eduWebsiteProfileMapper.selectByPrimaryKey(id);
    }
}
